
require.config({
    baseUrl : '',
    waitSeconds : 0,
    paths : {
        "jquery" : "./node_modules/jquery/dist/jquery.min",
        "bootstrap" : "./node_modules/bootstrap/dist/js/bootstrap.min",
        "angular":"./node_modules/angular/angular",
//        "angularAnimate":"./node_modules/angular-animate/angular-animate.min",
//      "angularLocale":"lib/angularjs/i18n/angular-locale_zh-cn",

        "md5":"./md5",
        
        "common" : "js/common.min",
        "resize" : "js/resize.min",
        
        "app":"js/app",
        
//        "services":"js/_services/services",
//        "filters":"js/_filters/filters.min",
        "directives":"js/_directives/directives",

//        "u2frame":"js/_directives/u2frame.min",
        "treeView":"js/_directives/treeView",
//        "u2Echarts":"js/_directives/u2Echarts.min",
//        "attachments":"js/_directives/attachments.min",
//        "attachphoto":"js/_directives/attachphoto",
        
        "controllers":"js/controllers",
        "subcontrollers":"js/subcontrollers",

        "BizData":"./component/BizData.min",

        "uiBootstrap":"./node_modules/angular-ui-bootstrap/dist/ui-bootstrap-tpls",

        "ocLazyLoad":"./node_modules/oclazyload/dist/ocLazyLoad.require.min",
        
        "bootstrapDatepicker":"./node_modules/bootstrap-datepicker/dist/js/bootstrap-datepicker.min",
        
        "bootstrapSwitchJs" : "./node_modules/bootstrap-switch/dist/js/bootstrap-switch.min",
        
        
//      "echartsSimple":"plugins/echarts3.3.1/simple/echarts.simple.min",//只包含基础图表折 柱 饼
//        "echartsCommon":"plugins/echarts3.3.1/common/echarts.common.min",//包含常用的图表组件 折 柱 饼 散点 图例 工具栏 标注/线/域 数据区域缩放
//      "echartsMin":"plugins/echarts3.3.1/simple/echarts.min",//包含所有图表组件
//      "echartsAll":"plugins/echarts/echarts-all",
        
        "loadingoverlay":"./node_modules/gasparesganga-jquery-loading-overlay/dist/loadingoverlay.min",
        
//        "FileAPI":"plugins/ng-file-upload/FileAPI.min",
//        "angularSanitize":"plugins/angular-sanitize/angular-sanitize.min",
//        "wysiwyg":"plugins/ngWYSIWYG/dist/wysiwyg.min",
        
//        "summernote":"plugins/angular-summernote/components/summernote/dist/summernote",
//        "angularSummernote":"plugins/angular-summernote/dist/angular-summernote",
        
        "uiRouter":"./node_modules/@uirouter/angularjs/release/angular-ui-router.min",

    },
    shim : {

        "jquery":{
            exports:"jquery"
        },
        "bootstrap" : {
            deps : ['jquery'],
            exports : "bootstrap"
        },
        "common" : {
            deps : ['bootstrap'],
            exports : "common"
        },
        "angular":{
            exports:"angular"
        },
        "angularAnimate":{
            deps : ['angular'],
            exports:"angularAnimate"
        },
        "uiRouter":{
            deps : ['angular'],
            exports:"uiRouter"
        },
        "uiBootstrap":{
            deps : ['angular'],
            exports:"uiBootstrap"
        },
        "loadingoverlay":{
            deps : ['jquery'],
            exports:"loadingoverlay"
        },
//        "tinymce":{
//            deps : ['FileAPI'],
//            exports:"tinymce"
//        },
//        "uiTinymce":{
//            deps : ['tinymce','angular'],
//            exports:"uiTinymce"
//        },
        
//        "bootstrapSysiwyg":{
//            deps : ['bootstrap'],
//            exports:"bootstrapSysiwyg"
//        },
        
        /*
        "angularSanitize":{
            deps : ['angular'],
            exports:"angularSanitize"
        },
        "FileAPI":{
            deps : [],
            exports:"FileAPI"
        },
        "wysiwyg":{
            deps : ['angularSanitize','FileAPI'],
            exports:"wysiwyg"
        },
        */

//        "ngFileUpload":{
//            deps : ['angular'],
//            exports:"ngFileUpload"
//        },
        
//        "bootstrapSuggest":{
//            deps : ['jquery','bootstrap'],
//            exports:"bootstrapSuggest"
//        },
        "bootstrapDatepicker":{
            deps : ['jquery'],
            exports:"bootstrapDatepicker"
        },
//        "bootstrap-datepicker-zh-CN":{
//            deps : ['jquery'],
//            exports:"bootstrap-datepicker-zh-CN"
//        },
        
        "bootstrapDatetimepicker":{
            deps : ['jquery'],
            exports:"bootstrapDatetimepicker"
        },

        "bootstrapSwitchJs":{
            deps : ['jquery','bootstrap'],
            exports:"bootstrapSwitchJs"
        },
//        "bootstrapTreeview":{
//            deps : ['jquery'],
//            exports:"bootstrapTreeview"
//        },

//		"summernote":{
//            deps : ['jquery'],
//            exports:"summernote"
//        },
//        "angularSummernote":{
//            deps : ['summernote'],
//            exports:"angularSummernote"
//        },
        
        
        "ocLazyLoad":{
            deps : ['angular'],
            exports:"ocLazyLoad"
        },

//        "attachments":{
//            deps : ['ngFileUpload'],
//            exports:"attachments"
//        },

//        "attachphoto":{
//            deps : ['ngFileUpload'],
//            exports:"attachphoto"
//        },

    }
    ,deps:['bootstrap'],
//  urlArgs: "bust=" + (new Date()).getTime()  //防止读取缓存，调试用

});

//require(['common'],function(common){
//    common.hello('require1');
//});

//require(['pace'], function(pace){
//	console.log('pace-->',pace);
//  pace.start({
//    document: false
//  });
//});

//日期控件语言包初始化
require(['bootstrapDatepicker'], function (bootstrapDatepicker) {
	$.fn.datepicker.dates["zh-CN"]={days:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],daysShort:["周日","周一","周二","周三","周四","周五","周六"],daysMin:["日","一","二","三","四","五","六"],months:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthsShort:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],today:"今日",clear:"清除",format:"yyyy年mm月dd日",titleFormat:"yyyy年mm月",weekStart:1};
//	$('.datepicker').datepicker({
//	});
});


require(['angular','resize','bootstrap','app'],function(angular,resize){
    angular.element(document).ready(function(){
//		console.log('angular.element(document).ready！');
    	resize.resize();
        angular.bootstrap(document,['backcenter']);
    });
    $(window).resize(function(){
    	resize.resize();
//    	console.log('$(window).resize');
    });
});

//require(["domReady!"],function(){
//	console.log('require domReady!');
//});



